package com.wft.factory.simple;

public abstract class Factory implements Api {
    public static Api createImpl(int type) {
        if (type == 1) {
            return new ImplA();
        } else if (type == 2) {
            return new ImplB();
        } else {
            return System.out::println;
        }
    }
}
